package com.klw.business.mapper;

import com.klw.business.domain.KlmBatchModel;
import com.klw.business.domain.KlwMlFeatures;
import com.klw.business.domain.QueryDataParam;
import com.klw.business.domain.RadarData;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 机器学习特征Mapper接口
 *
 * @author klw
 * @date 2025-08-24
 */
public interface KlwMlFeaturesMapper {
    /**
     * 查询机器学习特征
     *
     * @param featureId 机器学习特征主键
     * @return 机器学习特征
     */
    public KlwMlFeatures selectKlwMlFeaturesByFeatureId(Long featureId);

    /**
     * 查询机器学习特征列表
     *
     * @param klwMlFeatures 机器学习特征
     * @return 机器学习特征集合
     */
    public List<KlwMlFeatures> selectKlwMlFeaturesList(KlwMlFeatures klwMlFeatures);

    /**
     * 新增机器学习特征
     *
     * @param klwMlFeatures 机器学习特征
     * @return 结果
     */
    public int insertKlwMlFeatures(KlwMlFeatures klwMlFeatures);

    /**
     * 修改机器学习特征
     *
     * @param klwMlFeatures 机器学习特征
     * @return 结果
     */
    public int updateKlwMlFeatures(KlwMlFeatures klwMlFeatures);

    /**
     * 删除机器学习特征
     *
     * @param featureId 机器学习特征主键
     * @return 结果
     */
    public int deleteKlwMlFeaturesByFeatureId(Long featureId);

    /**
     * 批量删除机器学习特征
     *
     * @param featureIds 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteKlwMlFeaturesByFeatureIds(Long[] featureIds);

    /**
     * 判断学生指定学期特征值是否存在
     *
     * @param klmBatchModel
     * @return
     */
    public KlwMlFeatures selectFeatureByParam(KlmBatchModel klmBatchModel);

    /**
     * 获取所有学生指定学期特征值
     *
     * @return
     */
    public List<KlwMlFeatures> selectAll();

    /**
     * 根据学生ID和学期ID获取学生特征数据
     *
     * @param studentId  学生ID
     * @param semesterId 学期ID
     * @return
     */
    public KlwMlFeatures selectByStudentAndSemester(@Param("studentId") Long studentId, @Param("semesterId") Long semesterId);

    /**
     * 获取指定学期的所有学生特征数据
     *
     * @param semesterId 学期ID
     * @return
     */
    public List<KlwMlFeatures> selectBySemester(@Param("semesterId") Long semesterId);

    /**
     * 获取雷达图
     * @param param 查询参数
     * @return
     */
    public RadarData getRadarData(@Param("queryParam") QueryDataParam param);
}
